<template>
  <div class="sys-content-layout">
    <!-- 头部按钮、搜索区域 -->
    <div
      v-if="$slots.header"
      class="bg-white p-$layout-padding sys-content-layout-header"
    >
      <slot name="header"></slot>
    </div>
    <!-- 表格区域 -->
    <div
      class="sys-content-layout-body"
      :class="[$slots.default && 'bg-white p-$layout-padding', $slots.header && 'mt-$layout-padding']"
    >
      <!-- 单表格 -->
      <slot v-if="$slots.default"></slot>
      <!-- 左树右表格 -->
      <div v-else class="flex">
        <div class="bg-white mr-$layout-padding">
          <slot name="left"></slot>
        </div>
        <div class="bg-white p-$layout-padding flex-1 overflow-hidden">
          <slot name="right"></slot>
        </div>
      </div>
    </div>
  </div>
</template>